package com.isoft.systemprovidor.controller;

import com.isoft.systemprovidor.bean.ResponseData;
import com.isoft.systemprovidor.entity.ExternalManage;
import com.isoft.systemprovidor.service.ExternalManageService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@CrossOrigin
@RestController
@Slf4j
@RequestMapping("/systemprovidor/external")
public class ExternalManageController extends BaseController{
    @Autowired
    ExternalManageService externalManageService;

    /*获取外聘须知*/
    @GetMapping("/getexternal")
    public ResponseData<Object> getExternalManage(){
       return returnObject(externalManageService.getExternalManage());
    }

    /*修改外聘须知*/
    @PutMapping("/updateexternal")
    public ResponseData<Boolean> updataExternal(@RequestBody ExternalManage externalManage){
        return  returnBoolean(externalManageService.updataExternal(externalManage));
    }
}
